<!DOCTYPE html>
<html>
<head>
    <div th:include="base-libs :: base-libs" ></div>
    <title>转介中详情</title>
    <style type="text/css">
        .form-table td {
            padding: 1px;
        }

        .form-table input,select {
            width: 100% !important;
        }

        .td-text {
            text-align: right;
            background: #f7f9fb;
            width: 90px;
            vertical-align: middle !important;
            color: #666;
        }

        .td-content {
            vertical-align: middle !important;
        }

        input,select {
            height: 28px !important;
            line-height: 28px !important;
            padding-left: 4px !important;
            box-sizing: border-box !important;
        }

        .panel {
            margin: 4px 2px;
        }

        .panel-header {
            padding: 10px 5px;
            background: #F2F2F2;
        }

        .panel-body {
            padding-bottom: 2px;
        }

        .panel-tool span {
            margin-right: 20px;
            font-weight: bold;
            cursor: pointer;
            color: #2AC672;
        }

        .rqflLi {
            display: inline-block;
            border: 1px solid #D4D4D4;
            vertical-align: middle;
            padding-right: 8px;
            margin-right: 35px;
            margin-bottom: 4px;
            margin-top: 4px;
            width: 170px;
        }

        .rqflLi label {
            display: inline-block;
            height: 30px;
            padding: 0px 6px;
            margin-right: 4px;
            text-align: center;
            background-color: #f7f9fb;
            border-right: 1px solid #D4D4D4;
        }

        .switchbutton {
            margin-bottom: 2px;
        }

        .switchbutton-on {
            background: #1ea15b;
            color: #fff;
        }

        .fwbLi {
            display: inline-block;
            border: 1px solid #D4D4D4;
            vertical-align: middle;
            padding-right: 8px;
            margin-right: 10px;
            margin-bottom: 4px;
            margin-top: 4px;
        }

        .fwbLi label {
            display: inline-block;
            height: 30px;
            padding: 0px 6px;
            margin-right: 4px;
            text-align: center;
            background-color: #f7f9fb;
            border-right: 1px solid #D4D4D4;
        }

        .fwbLi .fwbsx span {
            display: inline-block;
            height: 100%;
            cursor: pointer;
        }

        .fwbLi input {
            display: inline-block;
            width: 14px !important;
            height: 14px !important;
            vertical-align: middle;
            margin-bottom: 2px;
        }

        .jtcyCzDiv {
            vertical-align: middle;
            text-align: center;
            /* width: 80px; */
        }

        .jtcyCzDiv a {
            margin: auto 4px;
            line-height: 28px;
        }
        .panel,.panel-header,.panel-body{
            width:100% !important;
        }
    </style>

    <script th:src="'/service/js/jtqy.js'"></script>

    <script th:inline="javascript">
        /**读取request中的初始化数据*/
        var data = [[${data}]];
    </script>
    <script type="text/javascript">
        var zydmCache = {};
        var JTQYINFO = StoreCache.removeCache("JTQYXQINFO");//家庭签约数据
        //alert(JSON.stringify(JTQYINFO));
        var BACKINFO = StoreCache.getCache("BACKINFO");//跳转页面
        var removeDetailBtn = StoreCache.removeCache("removeDetailBtn");
        $(function() {
            initData();
        });

        function initData(){
            $("body").data("qyxx",JTQYINFO);
            $("#QYXXID").val(JTQYINFO.QYXXID);
            var information = qyxxFormatData(JTQYINFO);
            information.SZYY = information["YLJGMC"];
            information.TDMC = information["QYTDMC"];
            information.JLRY = information["QYYS"];

            var timeReg = /^(\d{4}-\d{2}-\d{2})\s+00:00:00/;
            $(".form-control").each(function(){
                var name = $(this).attr("name");
                var value = information[name];
                if(!StringUtils.isEmpty(value)) value = value.replace(timeReg,"$1");
                if($(this).hasClass("isTitle")){
                    $(this).attr("title",value);
                }
                $(this).val(value);
            })
            var jtcy = data.JTCY;
            if(!StringUtils.isEmpty(jtcy)){
                $.each(jtcy,function (index,obj){
                    JtcyHandler(obj);
                })
            }
        }

        /** 导出功能 */
        function downExcel(){
            $("#exportData").val(JSON.stringify(new Array(JTQYINFO)));
            $("#exportForm").submit();
        }

        /** 打印协议  */
        function printXy(){
            $("#printForm")[0].submit();
        }

        /*查询历史记录*/
        function findLsjl(){
            findQyxxLsjl(JTQYINFO.JMXXID);
        }
        //导出功能
        /*  function downExcel(){
         $("#exportForm").submit();
         } */

        /**返回回调*/
        function btnBackHandler()
        {
            $.QuickUrlUtils.redirectUrl(BACKINFO);
        }
    </script>
</head>
<body class="easyui-layout">
<div region="north"
     style="height: 41px; border: none; overflow: hidden; background-color: #f9f9f9;">
    <div class="title">
        <h3>签约详情</h3>
    </div>
</div>
<div region="center" style="overflow-x: hidden; border: none;">
    <div>
        <div th:include="common/qyxqModelEasy :: qyxqModelEasy"></div>
    </div>
    <div class="easyui-panel" title="转介信息"
         data-options="tools:'#toolQyxx'">
        <table class="form-table">
            <tr>
                <td class="td-text"><label>申请时间：</label></td>
                <td><input type="text" id="SQRQ" name="SQRQ"
                           readonly="readonly" autocomplete="off"
                           class="layui-input form-control isTitle"></td>
                <td class="td-text"><label>申请用户：</label></td>
                <td><input type="text" id="SQYS" name="SQYS"
                           readonly="readonly" autocomplete="off"
                           class="layui-input form-control isTitle"></td>
                <td class="td-text"><label>转介申请团队：</label></td>
                <td>
                    <input type="text" name="QYTDMC" readonly="readonly" autocomplete="off"
                           class="layui-input form-control">
                </td>
            </tr>
            <tr>
                <td class="td-text"><label>转入团队：</label></td>
                <td class="td-content">
                    <input type="text" name="XQYTDMC" readonly="readonly" autocomplete="off"
                            class="layui-input form-control isTitle">
                </td>
                <td class="td-text"><label>转介原因：</label></td>
                <td class="td-content">
                    <input type="text"  name="ZJYYMS" readonly="readonly" autocomplete="off"
                            class="layui-input form-control isTitle">
                </td>
                <td class="td-text"><label>转介状态：</label></td>
                <td class="td-content">
                    <input type="text"  name="QYZT" readonly="readonly" autocomplete="off"
                           class="layui-input form-control isTitle">
                </td>
            </tr>
        </table>
    </div>
</div>
<div region="south" style="height: 41px; border: none; overflow: hidden; background-color: #f9f9f9; padding-top: 6px; text-align: center;">
    <button class="btn btn-info" type="button" onclick="btnBackHandler()">返回</button>
</div>
</body>
<script type="text/html" id="fwbLi">
    <li class="fwbLi">
        <label></label>
        <input class="easyui-switchbutton">
        <span class="fwbsx">
			<span><input type="radio" value="1">个人</span>
			<span><input type="radio" value="2">家庭</span>
		</span>
    </li>
</script>
<script type="text/html" id="cyxxTr">
    <tr class="cyxxTr">
        <td class="td-text">
            <label>身份证号：</label>
        </td>
        <td class="td-content" style="width: 160px;">
            <input type="text" autocomplete="off" name="SFZH" readonly="readonly"
                   class="form-control">
        </td>
        <td class="td-text">
            <label>成员姓名：</label>
        </td>
        <td class="td-content" style="width: 120px;">
            <input type="text" autocomplete="off" name="XM" readonly="readonly"
                   class="form-control">
        </td>
        <td class="td-text">
            <label>成员关系：</label>
        </td>
        <td class="td-content" style="width: 160px;">
            <input type="text" autocomplete="off" name="XMMC" readonly="readonly"
                   class="form-control">
        </td>
        <td class="td-content" style="min-width: 210px;">
            <input type="text" readonly="readonly" name="QYXX" autocomplete="off"
                   class="form-control isTitle" onmouseover="this.title=this.value">
        </td>
        <td>
            <div class="jtcyCzDiv">
                <input name="RYSX" class="form-control" hidden="hidden" >
                <a class="jtcyBtn" action="remove">移除</a>
                <!-- <button class="btn btn-info jtcyBtn" type="button" action="remove">移除</button> -->
            </div>
        </td>
    </tr>
</script>
</html>
